package com.csun.cmny.provider.dto;

import com.csun.cmny.provider.model.domain.OmcShifts;
import com.csun.cmny.provider.validator.OmcPlanAddValidator;
import com.csun.cmny.provider.validator.OmcPlanEditValidator;
import lombok.Data;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.Date;
import java.util.List;

@Data
public class PlanDto implements Serializable {

    private static final long serialVersionUID = -6385696447158253956L;

    /**
     * Id
     */
    @NotNull(message = "{plan.id.null}",
            groups = {OmcPlanEditValidator.class})
    private Long id;

    /**
     * 版本号
     */
    private Integer version;

    /**
     * 排班方案名称
     */
    @NotNull(message = "{plan.name.null}",
            groups = {OmcPlanAddValidator.class})
    @NotEmpty(message = "{plan.name.null}",
            groups = {OmcPlanAddValidator.class})
    private String name;

    /**
     * 机构id
     */
    private Long groupId;

    /**
     * 该方案是否被采用 0 没有 大于0表示采用
     */
    private Integer isUsed;

    /**
     * 创建人
     */
    private String creator;

    /**
     * 创建人ID
     */
    private Long creatorId;

    /**
     * 创建时间
     */
    private Date createdTime;

    /**
     * 最近操作人
     */
    private String lastOperator;

    /**
     * 最后操作人ID
     */
    private Long lastOperatorId;

    /**
     * 更新时间
     */
    private Date updateTime;

    /*
    * 交班List
    * */
    private List<OmcShifts> shiftsList;
}
